<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        /* !important权重为10000 */
        div.box{
            color: aqua !important;
        }
        /* id选择器权重为100 */
        #id{
            color: aquamarine;
        }
        /* 类选择器权重为10 */
        .one{
            color: red;
        }
        /* 元素选择器权重为1 */
        div{
            color: black;
        }
        /* 通配选择器权重为0 */
        *{
            color: yellow;
        }
    </style>
</head>
<body>
    <!-- 内联样式的权重是1000 -->
    <div id="main" class="box one two">我是div元素</div>
</body>
</html>